package com.example.microserviceorderservice.Service;

import com.example.microserviceorderservice.Mapper.OrderMapper;
import com.example.microserviceorderservice.entity.Order;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Service
public class OrderServiceImpl implements OrderService{
    @Resource
    OrderMapper orderMapper;

    public List<Order> getOrderById(int id) {
        return (orderMapper.getOrderById(id));
    }
    public List<Order> getOrderByUserName(String userName) {
        return (orderMapper.getOrderByUserName(userName));
    }
}
